#ifndef __EN2CH_H__
#define __EN2CH_H__

#define ARRAY_SIZE(a) (sizeof(a)/sizeof(a[0]))
#define MAX_WORD_LEN 32
#define MAX_EXPLANATION_LEN 256
#define ALL_WORDS_NUM 44387
#define ALL_EXPLANATION_NUM 44387
#define LIB_PATH_EN_WORDS "words_lib.h"
#define LIB_PATH_CN_EXPLANATION "ch_explanation_lib.h"
#define LIB_PATH_EN_EXPLANATION "en_explanation_lib.h"

typedef enum
{
	LIB_TYPE_WORDS = 0,
	LIB_TYPE_CN_EXPLANATION,
	LIB_TYPE_EN_EXPLANATION,
	LIB_TYPE_END
}e_libType;

typedef struct
{
	char *word;
}t_enWordItem;

typedef struct
{
	char *explanation;
}t_wordExplanation;

typedef unsigned long u32;
typedef unsigned short u16;
typedef unsigned char u8;

typedef struct  
{
	char firstChar;
	u16 offset;
}t_firstCharOffset;

t_firstCharOffset g_firstCharOffset[]=
{
	'a',0, 
	'b',2873,
	'c',5360,
	'd',10066,
	'e',13075,
	'f', 15106,
	'g',17073,
	'h',18577,
	'i',20255,
	'j',22426,
	'k',22825,
	'l',23210,
	'm',24689,
	'n',27274,
	'o',28289,
	'p',29457,
	'q',33515,
	'r',33766,
	's',36057,
	't',40035,
	'u',40952,
	'v',41907,
	'w',42789,
	'x',44060,
	'y',44103,
	'z',44236,
	'E',ALL_WORDS_NUM
};
#endif /* __EN2CH_H__ */